import Vue from 'vue';

export namespace N_flowMonitor {
  export interface flowInfo {
    label: string;
    code: string;
    value: number;
  }

  export interface wasteWaterInfo {
    // ID
    id: number;
    // 瞬时流量
    instantaneousFlow: flowInfo;
    // 瞬时流速
    instantaneousVelocity: flowInfo;
    // 流量百分比
    flowPercentage: flowInfo;
    // 正向累计整数
    forwardTotalInt: flowInfo;
    // 正向累计小数
    forwardTotalDecimal: flowInfo;
    // 反向累计整数
    reverseTotalInt: flowInfo;
    // 反向累计小数
    reverseTotalDecimal: flowInfo;
    // 流量电导比
    flowConductanceRatio: flowInfo;
    // 是否在线
    online: boolean;
    // 上次流量
    prevFlow: number;
  }

  export interface otherFlowInfo {
    // 压缩空气总流量
    compressedAir: flowInfo;
    // 纯水总流量
    pureWater: flowInfo;
    // 蒸汽流量
    steam: flowInfo;
    // 自来水总流量
    tapWater: flowInfo;
  }

  export interface cFlowMonitor extends Vue {
    wasteWaterData: wasteWaterInfo[];
    otherFlowData: otherFlowInfo;
    updateData: (data: any) => void;
  }
}
